![]() |
SetFPos |
||||
Header: | Files.h | Carbon status: | Supported | |
Sets the position of the file mark before reading from or writing to an open file.
OSErr SetFPos ( SInt16 refNum, SInt16 posMode, SInt32 posOff );
The file reference number of an open file.
The positioning mode. The posMode parameter indicates how to position the mark; it must contain one of the values described in
If you specify fsAtMark, the mark is left wherever it’s currently positioned, and the posOff parameter is ignored. The fsFromStart, fsFromLEOF, and fsFromMark constants let you position the mark relative to either the beginning of the file, the logical end-of-file, or the current mark. If you specify one of these three constants, you must also pass in posOff a byte offset (either positive or negative) from the specified point. If you specify fsFromLEOF, the value in posOff must be less than or equal to 0.
The positioning offset.
A result code.
Supported in Carbon. Available in Mac OS 8.1 and later when Carbon 1.0.2 or later is present.
© 2000 Apple Computer, Inc. — (Last Updated 5/8/2000)